<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<script src="../js/vue.min.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div id="app">
			<input type="text" v-focus="true" />
		</div>
		<script type="text/javascript">
			Vue.directive("focus",{
				inserted(el,bin){
					if(bin.value){
						el.focus()
					}
				}
			})
			var vm = new Vue({
				el:'#app'
			})
		</script>
	</body>
</html>
